package com.xiaoxx.coin.impl;


import com.xiaoxx.coin.FuturesClientImpl;
import com.xiaoxx.coin.config.BianceUrlDefaultConfig;
import com.xiaoxx.coin.impl.futures.Account;
import com.xiaoxx.coin.impl.futures.Market;

public class UMFuturesClientImpl extends FuturesClientImpl {
    private static String defaultBaseUrl = BianceUrlDefaultConfig.BASE_URL;
    private static String umProduct = "/fapi";

    public UMFuturesClientImpl() {
        super(defaultBaseUrl, umProduct);
    }

    public UMFuturesClientImpl(String baseUrl) {
        super(baseUrl, umProduct);
    }

    public UMFuturesClientImpl(String apiKey, String secretKey) {
        super(apiKey, secretKey, defaultBaseUrl, umProduct);
    }

    public UMFuturesClientImpl(String baseUrl, boolean showLimitUsage) {
        super(baseUrl, umProduct, showLimitUsage);
    }

    public UMFuturesClientImpl(String apiKey, String secretKey, boolean showLimitUsage) {
        super(apiKey, secretKey, defaultBaseUrl, umProduct, showLimitUsage);
    }

    public UMFuturesClientImpl(String apiKey, String secretKey, String baseUrl) {
        super(apiKey, secretKey, baseUrl, umProduct);
    }

    @Override
    public Market market() {
        return new Market(getProductUrl(), getBaseUrl(), getApiKey(), getShowLimitUsage(), getProxy());
    }

    @Override
    public Account account() {
        return new Account(getProductUrl(), getApiKey(), getSecretKey(), getShowLimitUsage(), getProxy());
    }

}
